const domain = 'https://api.it120.cc/small4/'
function http({url,method='Get',data={},hander={}}){

  return new Promise((resolve,reject)=>{
    wx.request({
      url: domain + url,
      method,
      hander,
      data,
      success:(res)=>{

          resolve(res)
      },
      fail:(err)=>{

        reject(err)
      }
    })
  })
}
export {http}